﻿using System;
using System.Configuration;

namespace Ue.Core.Configuration
{
    public class NameTypeConfigurationElement : ConfigurationElement
    {
        public const string NameTypeConfigurationElementNameAttributeName = "name";
        public const string NameTypeConfigurationElementTypeAttributeName = "type";

        [ConfigurationProperty(NameTypeConfigurationElementNameAttributeName
            ,IsRequired=true)]
        public string Name 
        {
            get { return base[NameTypeConfigurationElementNameAttributeName] as string; }
            set { this[NameTypeConfigurationElementNameAttributeName] = value; }
        }

        [ConfigurationProperty(NameTypeConfigurationElementTypeAttributeName
            , IsRequired = true)]
        public string Type
        {
            get { return base[NameTypeConfigurationElementTypeAttributeName] as string; }
            set { this[NameTypeConfigurationElementTypeAttributeName] = value; }
        }
    }
}
